<template>
  <view>
    <!-- <uni-nav-bar
      left-icon="back"
      title="问题解答"
      fixed="true"
      status-bar="true"
      @clickLeft="goback"
    ></uni-nav-bar> -->
    <view class="title">解题思路</view>
    <view class="text">{{ list.formula }}</view>
    <view class="title">回答模板</view>
    <view class="text">{{ list.answer }}</view>
  </view>
</template>
<script>
import uniNavBar from "@/components/uni-nav-bar/uni-nav-bar.vue";
export default {
  components: { uniNavBar },
  onLoad: function (option) {
    if (option) {
      let list = JSON.parse(uni.getStorageSync("list"));
      this.list = list[option.index];
    }
  },
  data() {
    return {
      list: {},
    };
  },
  methods: {
    goback() {
      uni.reLaunch({
        url: `../question/index`
      });
    },
  },
};
</script>
<style lang="scss" scoped>
.title {
  width: 100%;
  height: 80upx;
  display: flex;
  align-items: center;
  justify-content: left;
  padding-left: 3%;
  background-color: rgb(255, 187, 0);
}
.text {
  width: 96%;
  padding: 10upx 2% 10upx 2%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  background: rgb(255, 136, 0);
}
</style>